<?php
declare (strict_types=1);

namespace app\admin\controller;

use app\admin\service\AuthService;
use app\common\service\AttachmentService;
use think\response\Json;

class Attachment extends AdminBaseController
{
    protected $allowAllAction = [
        'Attachment/upload',
    ];

    // 上传
    public function upload():Json
    {
        $AttachmentService = new AttachmentService(AuthService::isLogin());
        return json($AttachmentService->upload());
    }
}
